package com.project.bean;

import com.fasterxml.jackson.annotation.JsonFormat;

import java.time.LocalDate;

public class UserBean {
    private int id;
    private String code;
    private String pwd = "111";
    private String mail;
    private String face;
    @JsonFormat(pattern = "yyyy-MM-dd")
    private LocalDate createDate = LocalDate.now();

    public UserBean() {
    }

    public UserBean(String code, String mail, String face) {
        this.code = code;
        this.mail = mail;
        this.face = face;
    }

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public String getCode() {
        return code;
    }

    public void setCode(String code) {
        this.code = code;
    }

    public String getPwd() {
        return pwd;
    }

    public void setPwd(String pwd) {
        this.pwd = pwd;
    }

    public String getFace() {
        return face;
    }

    public void setFace(String face) {
        this.face = face;
    }

    public String getMail() {
        return mail;
    }

    public void setMail(String mail) {
        this.mail = mail;
    }

    public LocalDate getCreateDate() {
        return createDate;
    }

    public void setCreateDate(LocalDate createDate) {
        this.createDate = createDate;
    }

    @Override
    public String toString() {
        return "UserBean{" +
                "id=" + id +
                ", code='" + code + '\'' +
                ", pwd='" + pwd + '\'' +
                ", mail='" + mail + '\'' +
                ", face='" + face + '\'' +
                ", createDate=" + createDate +
                "}\n";
    }
}
